package com.example.enterprisemanager.mvvm.fragment.manager;


import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.support.v7.widget.LinearLayoutManager;

import com.example.enterprisemanager.BR;
import com.example.enterprisemanager.R;
import com.example.enterprisemanager.base.BaseBackFragment;
import com.example.enterprisemanager.databinding.FragmentInputBinding;
import com.example.enterprisemanager.databinding.FragmentRuinBinding;

/**
 * A simple {@link Fragment} subclass.
 */
public class RuinFragment extends BaseBackFragment<FragmentRuinBinding, RuinViewModel> {


    public static RuinFragment newInstance() {
        return new RuinFragment();
    }

    @Override
    protected int getLayoutId() {
        return R.layout.fragment_ruin;
    }

    @Override
    protected Class<RuinViewModel> getModelClass() {
        return RuinViewModel.class;
    }

    @Override
    protected int getVariableId() {
        return BR.viewModel;
    }

    @Override
    protected void initView() {
        super.initView();
        mBinding.toolbar.setTitle(R.string.str_ruin_manager);
        initToolbarNav(mBinding.toolbar);

        mBinding.rvRuinGoods.setLayoutManager(new LinearLayoutManager(_mActivity));
        mBinding.rvRuinGoods.setAdapter(mViewModel.adapter);
    }

    @Override
    protected void initData(@Nullable Bundle savedInstanceState) {

    }

}
